package com.bilgeadam.swing.program;

import java.awt.BorderLayout;

import javax.swing.JButton;
import javax.swing.JFrame;

/**
 *
 * @author Bora SAYINER
 * @since Dec 13, 2014 12:27:06 PM
 * @version 1.0
 */
public class BorderLayoutSample {

	public static void main(String[] args) {
		JFrame frmMain = new JFrame();
		frmMain.setTitle("Border Layout");
		frmMain.setSize(800, 600);
		frmMain.setLocationRelativeTo(null);
		frmMain.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
		{
			{
				JButton button = new JButton("North Button");
				frmMain.add(button, BorderLayout.NORTH);
			}
			{
				JButton button = new JButton("South Button");
				frmMain.add(button, BorderLayout.SOUTH);
			}
			{
				JButton button = new JButton("East Button");
				frmMain.add(button, BorderLayout.EAST);
			}
			{
				JButton button = new JButton("West Button");
				frmMain.add(button, BorderLayout.WEST);
			}
			{
				JButton button = new JButton("Center Button");
				frmMain.add(button, BorderLayout.CENTER);
			}
		}
		frmMain.setVisible(true);
	}
}
